package com.huqing.icu.service.impl;

import org.springframework.ai.chat.memory.ChatMemory;
import org.springframework.ai.chat.messages.Message;
import org.springframework.stereotype.Service;

import java.util.List;

/**
 * @Description mysql存储对话信息
 * @Author huqing
 * @Date 2025/7/14 22:32
 **/
@Service
public class MySQLChatMemory implements ChatMemory {

    @Override
    public void add(String conversationId, List<Message> messageList) {
        /*for (Message message : messageList) {
            ChatMessage chatMessage = new ChatMessage();
            chatMessage.setParentId();
            chatMessage.setUserId();
            chatMessage.setChatSessionId(conversationId);
            chatMessage.setContent(message.getText());
            chatMessage.setRole(message.getMessageType().getValue());

        }*/


    }

    @Override
    public List<Message> get(String conversationId) {
        return null;
    }

    @Override
    public void clear(String conversationId) {

    }
}
